<template>
  <div class="baseB">
    B组件

    <button @click="sendMsg()">发消息</button>
  </div>
</template>

<script>
import Bus from '@/utils/EventBus'
export default {
  components: {

  },
  data() {
    return {

    }
  },

  methods: {
    sendMsg() {
      Bus.$emit('sendMsg', { type: '普通通知', msg: '这是来自B的消息' })
    }
  }
}
</script>

<style>
.baseB {
  width: 500px;
  height: 100px;
  background-color: blue;
}
</style>
